package com.example.springboot.entity;

    import com.baomidou.mybatisplus.annotation.FieldFill;
    import com.baomidou.mybatisplus.annotation.IdType;
    import com.baomidou.mybatisplus.annotation.TableField;
    import com.baomidou.mybatisplus.annotation.TableId;
    import com.baomidou.mybatisplus.annotation.TableName;
    import java.io.Serializable;
    import java.time.LocalDateTime;
import cn.hutool.core.annotation.Alias;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.example.springboot.config.LDTConfig;
    import lombok.Getter;
    import lombok.Setter;

/**
* <p>
    * 
    * </p>
*
* @author 子凡
* @since 2024-05-19
*/

    @Getter
    @Setter
    @TableName("sys_user")
    public class User implements Serializable {

    private static final long serialVersionUID = 1L;

            // 用户ID
            @Schema(description = "用户ID")
            @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

            // 用户名称
            @Schema(description = "用户名称")
    private String username;

            // 用户密码
            @Schema(description = "用户密码")
    private String password;

            // 用户邮箱
            @Schema(description = "用户邮箱")
    private String email;

            // 用户电话
            @Schema(description = "用户电话")
    private String phone;

            // 用户状态
            @Schema(description = "用户状态")
    private Boolean status;

            // 用户头像
            @Schema(description = "用户头像")
    private String avatar;

            // 逻辑删除
            @Schema(description = "逻辑删除")
    private Double deleted;

            // 用户角色
            @Schema(description = "用户角色")
    private String role;

            // 创建时间
            @Schema(description = "创建时间")
            @TableField(fill = FieldFill.INSERT)
            @JsonDeserialize(using = LDTConfig.CmzLdtDeSerializer.class)
            @JsonSerialize(using = LDTConfig.CmzLdtSerializer.class)
    private LocalDateTime createTime;

}
